<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@include file="../comum/CabecalhoTaglibComum.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>PAQS | Programa de Avaliação de Qualidade de Software</title>
<style>
<jsp:include page="/comum/geral.css"/>
</style> 
</head>
<f:view>
<body>
	<h:form id="listaIteracaooForm">
<%@include file="../comum/CabecalhoComum.jsp"%>
<%@include file="../comum/CabecalhoUsuarioComum.jsp"%>
<div class="corpo">
<%@include file="../comum/Mensagem.jsp"%>
	<div class="caminho">
		<h:outputText value="Onde você está: "></h:outputText>
		<h:commandLink value="Lista de Projetos" action="#{pc_ListaIteracao.voltarListaProjetos}"></h:commandLink>
		<h:outputText value=" >> "></h:outputText>
		<h:commandLink value="Projeto #{pc_ListaIteracao.projeto.nome}" action="#{pc_ListaIteracao.voltarProjetoEdit}"></h:commandLink>
		<h:outputText value=" >> "></h:outputText>
		<h:outputText value="Iterações"></h:outputText>
	</div>

	<h:dataTable value="#{pc_ListaIteracao.iteracoes}" var="iteracao"
 		width="100%" headerClass="dataTableHeader" rendered="#{!empty pc_ListaIteracao.iteracoes}">
		<h:column>
			<f:facet name="header">
				<h:outputText value="Número da iteração"/>
			</f:facet>
			<h:outputText value="#{iteracao.iteracaoPK.iterNumero}"></h:outputText>
		</h:column>

		<h:column>
			<f:facet name="header">
				<h:outputText value="Editar"></h:outputText>
			</f:facet>
			<h:commandLink action="#{pc_ListaIteracao.editar}" value="Editar">
				<f:param name="iterNumero" value="#{iteracao.iteracaoPK.iterNumero}"></f:param>
			</h:commandLink>
		</h:column>
	
		<h:column>
			<f:facet name="header">
				<h:outputText value="Excluir"></h:outputText>
			</f:facet>
			<h:commandLink value="Excluir" action="#{pc_ListaIteracao.excluir}">
				<f:param name="iterNumero" value="#{iteracao.iteracaoPK.iterNumero}"></f:param>
			</h:commandLink>
		</h:column>
	</h:dataTable>
<h:outputText value="Nenhuma iteração cadastrada" rendered="#{empty pc_ListaIteracao.iteracoes}"></h:outputText>
<p>
<h:commandButton styleClass="ButtonClass" value="Nova Iteração" action="#{pc_ListaIteracao.novaIteracao}"></h:commandButton>
</div>
<%@include file="../comum/RodapeComum.jsp"%>
</h:form>
</body>
</f:view>
</html>